fix: remove the dependency on protobuf-lite for tombstones#5157
Merged
supervacuus merged 4 commits intomainfrom Mar 9, 2026
Merged
fix: remove the dependency on protobuf-lite for tombstones#5157supervacuus merged 4 commits intomainfrom
supervacuus merged 4 commits intomainfrom
Conversation
Contributor
Semver Impact of This PR🟢 Patch (bug fixes) 📋 Changelog PreviewThis is how your changes will appear in the changelog. New Features ✨
Bug Fixes 🐛
🤖 This preview updates automatically when you update the PR. |
...ry-android-core/src/main/java/io/sentry/android/core/internal/tombstone/TombstoneParser.java
Show resolved
Hide resolved
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix prepared a fix for the issue found in the latest run.
- ✅ Fixed: NPE in
close()whentombstoneStreamis null- Added a null guard in
TombstoneParser.close()so try-with-resources no longer throws when constructed without an InputStream.
- Added a null guard in
Or push these changes by commenting:
@cursor push 9737b16a1a
Preview (9737b16a1a)
diff --git a/sentry-android-core/src/main/java/io/sentry/android/core/internal/tombstone/TombstoneParser.java b/sentry-android-core/src/main/java/io/sentry/android/core/internal/tombstone/TombstoneParser.java
--- a/sentry-android-core/src/main/java/io/sentry/android/core/internal/tombstone/TombstoneParser.java
+++ b/sentry-android-core/src/main/java/io/sentry/android/core/internal/tombstone/TombstoneParser.java
@@ -349,6 +349,8 @@
@Override
public void close() throws IOException {
- tombstoneStream.close();
+ if (tombstoneStream != null) {
+ tombstoneStream.close();
+ }
}
}
...ry-android-core/src/main/java/io/sentry/android/core/internal/tombstone/TombstoneParser.java
Show resolved
Hide resolved
markushi
approved these changes
Mar 9, 2026
Member
markushi
left a comment
There was a problem hiding this comment.
Nice straight-forward replacement, looks good to me!
Sentry Build Distribution
|
Contributor
Performance metrics 🚀
|
| Revision | Plain | With Sentry | Diff |
|---|---|---|---|
| ee747ae | 386.94 ms | 431.43 ms | 44.49 ms |
| 539ca63 | 313.51 ms | 355.43 ms | 41.92 ms |
| 22f4345 | 312.78 ms | 347.40 ms | 34.62 ms |
| 9fbb112 | 401.87 ms | 515.87 ms | 114.00 ms |
| fcec2f2 | 357.47 ms | 447.32 ms | 89.85 ms |
| d15471f | 361.89 ms | 378.07 ms | 16.18 ms |
| d15471f | 303.49 ms | 439.08 ms | 135.59 ms |
| 0eaac1e | 320.04 ms | 369.52 ms | 49.48 ms |
| a5ab36f | 320.47 ms | 389.77 ms | 69.30 ms |
| 27d7cf8 | 369.82 ms | 422.62 ms | 52.80 ms |
App size
| Revision | Plain | With Sentry | Diff |
|---|---|---|---|
| ee747ae | 1.58 MiB | 2.10 MiB | 530.95 KiB |
| 539ca63 | 1.58 MiB | 2.12 MiB | 551.41 KiB |
| 22f4345 | 1.58 MiB | 2.29 MiB | 719.83 KiB |
| 9fbb112 | 1.58 MiB | 2.11 MiB | 539.18 KiB |
| fcec2f2 | 1.58 MiB | 2.12 MiB | 551.50 KiB |
| d15471f | 1.58 MiB | 2.13 MiB | 559.54 KiB |
| d15471f | 1.58 MiB | 2.13 MiB | 559.54 KiB |
| 0eaac1e | 1.58 MiB | 2.19 MiB | 619.17 KiB |
| a5ab36f | 1.58 MiB | 2.12 MiB | 555.26 KiB |
| 27d7cf8 | 1.58 MiB | 2.12 MiB | 549.42 KiB |
1 task
romtsn
added a commit
to getsentry/rust-proguard
that referenced
this pull request
Mar 10, 2026
## Summary - Adds a daily GHA workflow that checks if the upstream R8 retrace mapping spec (`doc/retrace.md`) has been updated - Mirrors the approach from [sentry-java#5157](getsentry/sentry-java#5157) for the tombstone proto schema - Allows us to react to retrace format changes promptly ## Test plan - [x] Verified the script runs successfully locally and reports "Spec is up to date" 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

📜 Description
As the title says, it replaces the dependency on a huge generic protobuf decoder with a tiny tombstone-specific package called
epitaph(GH, central). The dependency is MIT licensed and can be incorporated into the Sentry ecosystem in whichever ways make sense down the road.💡 Motivation and Context
Part of the wrap-up milestone in https://linear.app/getsentry/project/tombstone-support-android-0024cb6e3ffd
https://linear.app/getsentry/issue/ANDROID-267/switch-to-dependency-free-protobuf-runtime
💚 How did you test it?
Tested the same way as the dependency it replaces. The library, though, has a battery of test cases for encoding errors and edge cases.
📝 Checklist
sendDefaultPIIis enabled.🔮 Next steps